/**
 *Copyright (c) 2024 watereyes
 * workflow is licensed under Mulan PubL v2.
 * You can use this software according to the terms and conditions of the Mulan
 * PubL v2.
 * You may obtain a copy of Mulan PubL v2 at:
 *          http://license.coscl.org.cn/MulanPubL-2.0
 * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
 * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
 * MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
 * See the Mulan PubL v2 for more details.
 */
package com.koron.workflow.applicationManag.mapper;

import com.koron.workflow.applicationManag.bean.WhiteListBean;
import com.koron.workflow.applicationManag.bean.WhiteListQueryBean;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 白名单
 */
public interface WhiteListMapper {
    /**
     * 根据条件查询 白名单 列表
     *
     * @param appId    应用ID
     * @param pageSize
     * @return
     */
    List<WhiteListQueryBean> queryForList(@Param("appId") String appId, @Param("page") Integer page, @Param("pageSize") Integer pageSize);

    /**
     * 根据条件查询 白名单 总个数
     *
     * @param appId 应用ID
     * @return
     */
    Integer countQueryForList(@Param("appId") String appId);

    /**
     * 根据ID查询 白名单
     *
     * @param id
     * @return
     */
    WhiteListQueryBean queryForObject(String id);

    /**
     * 新增 白名单
     *
     * @param bean
     * @return
     */
    Integer insert(WhiteListBean bean);

    /**
     * 修改 白名单
     *
     * @param bean
     * @return
     */
    Integer update(WhiteListBean bean);

    /**
     * 根据ID删除 白名单
     *
     * @param id
     * @return
     */
    Integer delete(String id);
}
